home *** CD-ROM | disk | FTP | other *** search
/ Programming Windows 95 with MFC / Programming Windows 95 with MFC (Microsoft Programming Series)(097-0001465)(1996).iso / CODE / Chap10 / HexDump / HexView.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-04-05  |  1015 b   |  41 lines

  1. //***********************************************************************
  2. //
  3. //  HexView.h
  4. //
  5. //***********************************************************************
  6.  
  7. class CHexView : public CScrollView
  8. {
  9.     DECLARE_DYNCREATE (CHexView)
  10.  
  11. private:
  12.     CFont m_screenFont;
  13.     CFont m_printerFont;
  14.  
  15.     UINT m_cyScreen;
  16.     UINT m_cyPrinter;
  17.     UINT m_cxOffset;
  18.     UINT m_cxWidth;
  19.  
  20.     UINT m_nLinesTotal;
  21.     UINT m_nLinesPerPage;
  22.  
  23.     CHexDoc* GetDocument () { return (CHexDoc*) m_pDocument; }
  24.     void FormatLine (UINT, CString&);
  25.     void PrintPageHeader (CDC*, UINT);
  26.     void PrintPage (CDC*, UINT);
  27.  
  28. public:
  29.     virtual void OnInitialUpdate ();
  30.  
  31. protected:
  32.     virtual void OnDraw (CDC*);
  33.     virtual BOOL OnPreparePrinting (CPrintInfo*);
  34.     virtual void OnBeginPrinting (CDC*, CPrintInfo*);
  35.     virtual void OnPrint (CDC*, CPrintInfo*);
  36.     virtual void OnEndPrinting (CDC*, CPrintInfo*);
  37.  
  38.     afx_msg int OnCreate (LPCREATESTRUCT);
  39.     DECLARE_MESSAGE_MAP ()
  40. };
  41.